package com.resou.reader.discovery.comment;

import com.resou.reader.api.entry.BookListCommentBean;
import com.resou.reader.base.BasePresenter;
import com.resou.reader.base.BaseView;
import com.scwang.smartrefresh.layout.SmartRefreshLayout;

import java.util.List;

public interface ICommentContract {

    interface ICommentView extends BaseView {
        /**
         * 评论集合
         *
         * @param list
         * @param total 总评论数量
         */
        void showCommentData(List<BookListCommentBean.CommentsBean> list, int total);

        /**
         * 点赞
         *
         * @param
         */
        void showPraiseComment();

        /**
         * 取消点赞
         *
         * @param bookId
         */
        void showUnPraiseComment(String bookId);

        SmartRefreshLayout getSmartRefreshLayout();
    }

    interface ICommentPresenter extends BasePresenter {
        void quearCommentData(String bookListId, int page);

        /**
         * 点赞
         *
         * @param userId
         */
        void praiseComment(String userId);

        /**
         * 取消点赞
         *
         * @param userId
         */
        void unPraiseComment(String userId);
    }
}
